package cn.edu.nju.software.action.book;

import cn.edu.nju.software.service.intf.BookService;

import com.opensymphony.xwork2.ActionSupport;

@SuppressWarnings("serial")
public class DeleteBookAction extends ActionSupport {
	
	private int id;
	private BookService bookService;
	
	public void setId(int id) {
		this.id = id;
	}
	
	public void setBookService(BookService bookService) {
		this.bookService = bookService;
	}
	
	@Override
	public String execute() throws Exception {
		bookService.deleteBook(id);
		return SUCCESS;
	}
	

}
